
public class CatDog implements CatInterface, DogInterface, Animal{
	
	private Dog dogComponent;
	private Cat catComponent;
	
	public CatDog(){
		this.dogComponent = new Dog();
		this.catComponent = new Cat();
	}
	
	@Override
	public void bark() {
		System.out.println("I am a CatDoG and I can bark, listen:");
		dogComponent.bark();
	}

	@Override
	public void meow() {
		System.out.println("I am a CatDoG and I can meow, listen:");
		catComponent.meow();
	}

	@Override
	public void makeSound() {
		// TODO Auto-generated method stub
		System.out.println("I make sound: meow, woof");
	}
}
